<?php
$db = new PDO('mysql:host=localhost; dbname=db3', 'root', '12qwas');
$ps=$db->prepare('select * from students limit 1,2');
$ps->bindColumn(1,$xh);
$ps->bindColumn(2,$name);
$ps->bindColumn('age', $age, PDO::PARAM_INT);
$ps->execute();
foreach ($ps as $r){
    echo "{$xh}\t{$name}\t{$age}\n";
}